package com.dao;

import com.bean.Flower;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

public interface FlowerDao {

    public Integer queryForPageTotalCount();

    public List<Flower> queryForPageItem(int begin, int pageSize);

    public Integer queryForPageTotalCountByPrice(int min, int max);

    public List<Flower> queryForPageItemByPrice(int begin, int pageSize, int min, int max);

    public Integer queryForPageTotalCountByName(String flower_name);

    public List<Flower> queryForPageItemByName(int begin, int pageSize, String flower_name);

    public Flower queryFlowerByFlowerid(int id);

    public Integer queryForPageTotalCountByEnterpriseid(String enterpriseid);

    public List<Flower> queryForPageItemByEnterpriseid(int begin, int pageSize, String enterpriseid);

    public int updateFlower(Flower flower);

    public int addFlower(Flower flower);

    public int deleteFlowerByFlowerid(int flowerid);

    public Integer queryForPageTotalCountByFclassid(Integer fclassid);

    public List<Flower> queryForPageItemByFclassid(int begin, int pageSize, Integer fclassid);

    public int updateFlowerByFlower(Integer sales, Integer stock, Integer flowerid);

    public List<Flower> queryBySales();

    public List<Map<String, Object>> listquery(int flowerid);

    public int updateById(Integer flowerid, String flower_name, BigDecimal price, String introduce, Integer stock, Integer fclassid);

    public int insertFlower(String flower_name, BigDecimal price, String introduce, Integer stock, Integer fclassid, String enterpriseid, String flower_phoro, Integer sales);

    public int updatePhoto(Integer flowerid, String enterpriseid, String flower_photo);

    public List<Flower> queryByPrice(BigDecimal price);

    public List<Map<String, Object>> queryByName(String content);
}
